/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package db;

import java.util.ArrayList;

/**
 *
 * @author Lord Makuta
 */
public class ActorObj 
{
    private int id;
    private String name;
    private double rating;
    private ArrayList appeared;
    private String descLink;
    private char gender;
    private int age;
    
    public ActorObj(){
        id=0;name="";gender='m';age=0;rating=0;appeared=new ArrayList();descLink="";
    }
    public ActorObj(int nId,String nName,char nGender,int nAge){
        this.id = nId;this.name = nName;this.gender=nGender;this.age=nAge;
        this.rating=0;this.appeared=new ArrayList();
        this.descLink="./images/actors/actor"+id+".txt";
        gender=nGender;
        age=nAge;
    }

    /**
     * @return the id
     */
    public int getId() {
        return id;
    }

    /**
     * @return the name
     */
    public String getName() {
        return name;
    }

    /**
     * @return the rating
     */
    public double getRating() {
        return rating;
    }

    /**
     * @return the appeared
     */
    public ArrayList getAppeared() {
        return appeared;
    }

    /**
     * @param id the id to set
     */
    public void setId(int id) {
        this.id = id;
    }

    /**
     * @param name the name to set
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * @param rating the rating to set
     */
    public void setRating(double rating) {
        this.rating = rating;
    }

    /**
     * @param appeared the appeared to set
     */
    public void setAppeared(ArrayList appeared) {
        this.appeared = appeared;
    }
    
    public void addAppeared(int newMovieId){
        this.appeared.add(newMovieId);
    }

    

    /**
     * @param gender the gender to set
     */
    public void setGender(char gender) {
        this.gender = gender;
    }

    /**
     * @return the age
     */
    public int getAge() {
        return age;
    }

    /**
     * @param age the age to set
     */
    public void setAge(int age) {
        this.age = age;
    }
    
    public String getGender()
    {
        if (gender=='M')
            return "Male";
        else
            return "Female";
    }
    
    
}
